package com.jie.web.controller;


import com.jie.service.UserInfoService;
import com.jie.util.UserUtils;
import com.jie.vo.CommonResponse;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author xiaojie
 * @since 2023-11-01
 */
@RestController
@RequestMapping("/user-info")
@Api(tags = "用户信息管理模块")
public class UserInfoController {
    @Autowired
    private UserInfoService userInfoService;
    @GetMapping("/getUserInfo")
    @ApiOperation(value = "获取当前用户信息接口")
    public CommonResponse getUserInfo(){
        return CommonResponse.buildSuccess(UserUtils.getLoginUser());
    }
}

